﻿using Microsoft.VisualBasic;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Data;
using System.Diagnostics;
using System.Runtime.Serialization;

namespace Framework.Data.Exceptions
{
    [Serializable()]
    public class AppException : ApplicationException
    {

        #region "Membres"
        #endregion
        protected List<AppExceptionParameter> _parameters = new List<AppExceptionParameter>();

        #region "Constructeurs"
        /// <summary>
        /// Constructeur
        /// </summary>
        /// <remarks></remarks>
        public AppException()
            : base()
        {
        }

        /// <summary>
        /// Constructeur
        /// </summary>
        /// <param name="messageID">Id du message à localizer</param>
        /// <remarks></remarks>
        public AppException(string messageID)
            : base(messageID)
        {
        }

        /// <summary>
        /// Constructeur
        /// </summary>
        /// <param name="messageID">Id du message à localizer</param>
        /// <param name="innerException">Exception interne</param>
        /// <remarks></remarks>
        public AppException(string messageID, Exception innerException)
            : base(messageID, innerException)
        {
        }

        /// <summary>
        /// Constructeur pour la sérialization
        /// </summary>
        /// <param name="info">Info</param>
        /// <param name="context">Context</param>
        /// <remarks></remarks>
        public AppException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }

        #endregion

        #region "Propriétés"
        public List<AppExceptionParameter> Parameters
        {
            get { return this._parameters; }
        }

        #endregion
    }
}